public class Main {
    private int a = 5;
    public void fun1( int b){

        //局部内部类
        class A{
            private int fun2(){
                return a + b;
            }
        }

        A a1 = new A();
        System.out.print(a1.fun2());
    }

    public static void main(String[] args) {
        Main m=new Main();
        m.fun1(1);
    }
}